]> dgit.raspbian.org Git - gnome-shell.git/commit
lint: Allow marking variables/arguments as unused
authorFlorian Müllner <fmuellner@gnome.org>
Mon, 28 Jan 2019 00:37:12 +0000 (01:37 +0100)
committerFlorian Müllner <fmuellner@gnome.org>
Tue, 23 Jul 2019 22:28:45 +0000 (00:28 +0200)
commit0257de1b7eb160e54e928f499e95dfbec6b634cf
treebca5fa1acf59fbb37ff6eec5cd750c9b4ec17c21
parent466dc8da8fa7243322fd12c8165f5a7f9d1eff29
lint: Allow marking variables/arguments as unused

Unused variables or arguments can indicate bugs, but they can also
help document the code, in particular in case of signal handlers
and destructuring.

Account for this by keeping the error, but set up patterns that allow
us to opt out of if for individual variables/arguments. For arguments
we pick a '_' prefix, while for variables we go with a suffix instead,
to not accidentally exempt private module-scope variables.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/627
lint/eslintrc-shell.json